package com.ruicar.afs.cloud.wechat.service.impl;


import com.alibaba.fastjson.JSONObject;
import com.ruicar.afs.cloud.wechat.dto.WechatDTO;
import com.ruicar.afs.cloud.wechat.feign.WechatFegin;
import com.ruicar.afs.cloud.wechat.service.WechatService;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service;

import java.util.Map;

@Slf4j
@Service
@Component
@AllArgsConstructor
public class WechatServiceImpl implements WechatService {
    private final WechatFegin wechatFegin;

    @Override
    public JSONObject getToken(Map<String, String> data) {
        return wechatFegin.getToken(data);
    }

    @Override
    public byte[] getScene(WechatDTO wechatDTO, Map<String, String> data) {
        return wechatFegin.getScene(wechatDTO, data);
    }
}
